Scripts are useful for
creating slide shows.
Scripts are useful for creating slide shows. Ordinarily,
the speed with which you can display slides is limited by the number
of times AutoCAD must access the disk to read the slide file.
You can, however, preload the next slide from disk into memory while
your audience is viewing the current slide and then quickly display
the new slide from memory.
To
preload a slide, place an asterisk before the file name in VSLIDE.
The next VSLIDE command detects that a slide has been preloaded
and displays it without asking for a file name.
The disk-access time to load the next slide
overlaps with the viewing time for the current slide. You can specify
additional delays with the DELAY command. Each delay unit is equal
to one millisecond.
To stop a repeating script
press ESC. You can resume the script with RESUME.
If the script will run
for a long time, it is recommended that you use UNDO Control None
to turn off the Undo log file.
To run slide shows from
scripts
To create a script that
preloads slides
In this example of a
script that displays three slides (files slide1.sld, slide2.sld, and slide3.sld),
the time it takes to access the disk drive and load the next slide into
memory overlaps with the viewing time for the current slide.
- On the first line of the script, enter vslide
slide1.
The first line begins
the slide show and loads slide1.
- On the second line, enter vslide
*slide2.
The asterisk (*) preceding
the slide name on the second line preloads slide2.
- On the third line, enter delay
2000.
The third line specifies
a delay of 2000 milliseconds to allow the audience to view slide1.
- On the fourth line, enter vslide.
On the fifth line, enter vslide *slide3. On the sixth line,
enter delay 2000.
The fourth, fifth, and sixth lines display slide2,
preload slide3, and specify a delay for
viewing slide2.
- On the seventh line, enter vslide.
On the eighth line, enter delay 3000.
The seventh and eighth lines display slide3 and
specify a delay for viewing slide3.
- On the last line, enter rscript to
repeat the script.
- To stop a repeating script press ESC.
To continue the script, enter resume.
The script may contain comments, as follows:
; Begin slide show, load SLIDE1
VSLIDE SLIDE1
; Preload SLIDE2
VSLIDE *SLIDE2
; Let audience view SLIDE1
DELAY 2000
; Display SLIDE2
VSLIDE
; Preload SLIDE3
VSLIDE *SLIDE3
; Let audience view SLIDE2
DELAY 2000
; Display SLIDE3
VSLIDE
; Let audience view SLIDE3
DELAY 3000
; Cycle
RSCRIPT
CommandsDELAY
Provides a timed pause
within a script.
GRAPHSCR
Switches from the text
window to the drawing area.
RESUME
Continues an interrupted
script.
RSCRIPTSCRIPT
Executes a sequence
of commands from a script file.
TEXTSCRVSLIDE
Displays an image slide
file in the current viewport.